﻿
IF  EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[sproc_BBS_AttachmentToItem]') AND type in (N'P', N'PC'))
    DROP PROCEDURE [dbo].[sproc_BBS_AttachmentToItem];
GO
CREATE PROCEDURE [dbo].[sproc_BBS_AttachmentToItem]
@filename nvarchar(500),
@itemid int
/*-------------------------------------
功能：记录贴子的附件信息
参数：
    @filename    文件名
    @itemid        贴子id
-------------------------------------*/
AS
    INSERT INTO UDS_BBS_Item_Attachment(item_id,filename)
    VALUES(@itemid,@filename)